#ifndef _events_h
#define _events_h

#include "evtracker.h"

#define EVENTS_TYPE_VCI 1
#define EVENTS_TYPE_DTIMER 2
#define EVENTS_TYPE_SIMOP 3

typedef struct events_t {

	evtracker_tp evtracker;

} events_t, * events_tp;

typedef struct events_eholder_t {
	void * d;
	int type;
} events_eholder_t, * events_eholder_tp;

events_tp events_create (void);
void events_schedule (events_tp events, ptime_t at, void * data, int type);
ptime_t events_get_next_time (events_tp events);
void * events_dequeue  (events_tp events, ptime_t * at, int * type);
void events_destroy (events_tp events);


#endif
